package com.icss.flow.enums;

import lombok.AllArgsConstructor;
import lombok.Getter;

/**
 * @author hyk
 */

@AllArgsConstructor
@Getter
public enum TaskStatusEnum {
    ALL(2,"全部"),
    FINISHED(1,"已办"),
    AGENDA(0,"待办");
    private final Integer status;
    private final String name;


    public static TaskStatusEnum getTask(Integer extName) {
        for (TaskStatusEnum value : TaskStatusEnum.values()) {
            if (value.getStatus().equals(extName)) {
                return value;
            }
        }
        return null;
    }
}
